package com.sunrise.xdoc.entity.config;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.Table;

import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.NotBlank;

import com.sunrise.xdoc.entity.AbstractCodeEntity;

/**
 * Code of country should be ISO code.
 * 
 */
@Entity
@Table(name = "config_country")
@Inheritance(strategy = InheritanceType.JOINED)
public class Country extends AbstractCodeEntity implements Serializable {
	private static final long serialVersionUID = 1L;
	private String name;

	@Column(name = "name", unique = true)
	@Length(max = 250)
	@NotBlank
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

}
